package com.newy.dao.misc;

import java.util.List;

import org.hibernate.criterion.Order;
import org.hibernate.criterion.Restrictions;
import org.springframework.stereotype.Repository;

import com.newy.core.hibernate.HibernateDao;
import com.newy.domain.misc.FqaValuation;

/**
 * 
 * @author linzongxue 2012-2-19
 *
 */
@Repository
public class FqaValuationDao extends HibernateDao<FqaValuation, Long> {
	/**
	 * 获取指定FQA内容的所有评价
	 */
	public List<FqaValuation> getAllOfPost(Long postId){
		return this.find(Restrictions.eq("postId", postId), Order.desc("createTime"));
	}
}
